﻿

using Microsoft.EntityFrameworkCore;
using Microsoft.EntityFrameworkCore.Metadata.Builders;
using SiyinPractice.Domain.FileByUploadAndDown;
using SiyinPractice.Infrastructure.EntityFramework.EntityConfigurations;

namespace SiyinPractice.Infrastruture.DataStore.FileByUploadAndDown.EntityConfigurations
{
    public class FileUploadAndDownConfiguration : AbstractEntityTypeConfiguration<FileUploadAndDown>
    {
        public override void Configure(EntityTypeBuilder<FileUploadAndDown> builder)
        {
            base.Configure(builder);
            builder.ToTable("sys_files_upload");
            builder.Property(x => x.FileName).HasColumnName("FileName").HasMaxLength(255);
            builder.Property(x => x.FileType).HasColumnName("FileType").HasMaxLength(500);
            builder.Property(x => x.FilePath).HasColumnName("FilePath");
            builder.Property(x => x.DownloadCount).HasColumnName("DownloadCount");
        }
    }
}